class BaseResult {
  code: number;
  message: string;
  data: any;
  constructor(code: number, message: string, data: any = null) {
    this.code = code;
    this.message = message;
    this.data = data;
  }
}
export class SuccessResult extends BaseResult {
  constructor(data?, message = 'success') {
    super(0, message, data);
  }
}
export class FailResult extends BaseResult {
  constructor(message: string, code: number = 1) {
    super(code, message);
  }
}
